{% extends 'home/extends/base.html' %}

{% block title %}
    <title>我的订单</title>
{% endblock %}

{% block css %}
    <link rel="stylesheet" type="text/css" href="/static/home/css/order.css">
    <link rel="stylesheet" type="text/css" href="/static/home/css/order-app.css">
    <script src="/static/admin/js/jquery.uploadView.js"></script>
{% endblock %}


{% block con %}
<div class="mainbody order">
    <div class="container">
        <!-- 面包屑导航 -->
        <div class="crumbs col-xs-12 col-sm-12">
            <ol class="breadcrumb">
                <li class="hidden-xs hidden-sm"><a href="/">首页</a></li>
                <li class="hidden-xs hidden-sm"><a href="/">我的商城</a></li>
                <li class="active">个人信息</li>
            </ol>
        </div><!-- 面包屑导航 E-->

        <div class="main clearfix">
            <!-- 左侧导航 -->
            <div class="left-nav f-fl col-md-4 hidden-xs hidden-sm">
                <div class="nav-main">
                    <a href="javascript:;" class="type-title"><span class="glyphicon glyphicon-list-alt" aria-hidden="true"></span>订单中心</a>
                    <a href="{% url 'home_myorder' %}" class="ml ">我的订单</a>

                    <a href="javascript:;" class="type-title"><span class="glyphicon glyphicon-user" aria-hidden="true"></span>个人中心</a>

                    <a href="{% url 'home_personal' %}" class="ml active">个人信息</a>
                    <a href="{% url 'home_address_list' %}" class="ml ">地址管理</a>

                </div>
            </div><!-- 左侧导航 E-->
            <!-- 右侧内容展示 -->
            <div>
                <form action="{% url 'home_up_personal' %} " method="post" enctype="multipart/form-data">
                    {% csrf_token %}
                    用户名：<input type="text" name="username" value="{{ data.username }}"><br><br>
                    手机号：<input type="text" name="phone" value="{{ data.phone }}"><br><br>
                    邮&nbsp;&nbsp;&nbsp;&nbsp;箱：<input type="text" name="email" value="{{ data.email }}"><br><br>
                    <div class="am-form-group">
                                <label for="user-weibo" class="am-u-sm-3 am-form-label">头&nbsp;&nbsp;&nbsp;&nbsp;像: </label>
                                <div class="am-u-sm-9">
                                    <div id="upimg" class="am-form-group am-form-file">
                                        <div class="tpl-form-file-img" id="showimg">
                                            <img src="{{ data.pic }} " alt="您还没有上传头像" width="100">
                                        </div>

                                        <input name="pic" id="doc-form-file" type="file" multiple="">
                                    </div>

                                </div>
                    </div>
                    <button style="margin:30px 0px 0px 50px ">点击修改</button>
                </form>
            </div>
    </div>
</div>
</div>
 <!-- 模态框 -->

{% endblock %}

{% block js %}
<script type="text/javascript">
//登录图片鼠标经过
      topLogin();
$("#doc-form-file").uploadView({
        uploadBox: '#upimg',//设置上传框容器
        showBox : '#showimg',//设置显示预览图片的容器
        width : 100, //预览图片的宽度，单位px
        height : 100, //预览图片的高度，单位px
        allowType: ["gif", "jpeg", "jpg", "bmp", "png"], //允许上传图片的类型
        maxSize :2, //允许上传图片的最大尺寸，单位M
        success:function(e){
            $(".js_uploadText").text('更改');
        }
    });

</script>
{% endblock %}